package com.finance.service;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.finance.dao.LoanBasicDao;
import com.finance.entity.LoanBasic;

@Service("adminLoanBasicService")
public class LoanBasicService {

	@Resource(name = "adminLoanBasicDao")
	private LoanBasicDao loanBasicDao;

	public void add(LoanBasic loanBasic) {
		loanBasicDao.add(loanBasic);
	}

	public List<LoanBasic> loanBasicListMoney(String yhUserId, String userId,
			Integer stillState, String loanId) {
		return loanBasicDao.loanBasicListMoney(yhUserId, userId, stillState,
				loanId);
	}

	public void update(LoanBasic loanBasic) {
		loanBasicDao.update(loanBasic);
	}

	/**
	 * 查看逾期金额
	 */
	public double findByOverMoney() {
		return loanBasicDao.findByOverMoney();
	}

	public List<LoanBasic> list() {
		return loanBasicDao.list();
	}

	public List<LoanBasic> findByState(Integer stillState) {
		return loanBasicDao.findByState(stillState);
	}

	public List<LoanBasic> findByLoanIdUserId(String loanId, String yhUserId,
			Integer stillState) {
		return loanBasicDao.findByLoanIdUserId(loanId, yhUserId, stillState);
	}

	public LoanBasic findById(String loanBasicId) {
		return loanBasicDao.findById(loanBasicId);
	}

}
